Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add pre-mine create commands #6432

Conversation

hansieodendaal
Copy link
Contributor

@hansieodendaal hansieodendaal commented Jul 26, 2024

Description

Added pre-mine creation command-line commands for the creation ceremony and support within the ledger application.

Motivation and Context

To support pre-mine.

How Has This Been Tested?

System-level testing with 4 ledger wallets and 1 software wallet.
Note: End-to-end spending can only be tested once a new pre-mine file has been generated.

Commands to wallets:

---------------
---- Step 1 --- (Wallet 1 - Ledger/Party member)
---------------

pre-mine-create-script-inputs --alias alice

---------------
---- Step 1 --- (Wallet 2 - Ledger/Party member)
---------------

pre-mine-create-script-inputs --alias bob

---------------
---- Step 1 --- (Wallet 3 - Ledger/Party member)
---------------

pre-mine-create-script-inputs --alias carol

---------------
---- Step 1 --- (Wallet 4 - Ledger/Fail safe)
---------------

pre-mine-create-script-inputs --alias dave

---------------
---- Step 2 --- (Wallet 5 - Software/Leader)
---------------

pre-mine-create-genesis-file --party-file-names=tari_pre_mine\create\step_1_for_leader_from_alice.json 
 --party-file-names=tari_pre_mine\create\step_1_for_leader_from_bob.json 
 --party-file-names=tari_pre_mine\create\step_1_for_leader_from_carol.json 
 --fail-safe-file-name \tari_pre_mine\create\step_1_for_leader_from_dave.json

---------------
---- Step 3 --- (Wallet 1 - Ledger/Party member)
---------------

pre-mine-create-verify-genesis-file --session-id H6HvkTjpMC1ZhsQ7 --party-file-names=step_1_for_leader_from_alice.json 
 --party-file-names=step_1_for_leader_from_bob.json --party-file-names=step_1_for_leader_from_carol.json 
 --fail-safe-file-name step_1_for_leader_from_dave.json --pre-mine-file-name ./esmeralda_pre_mine.json

---------------
---- Step 3 --- (Wallet 2 - Ledger/Party member)
---------------

pre-mine-create-verify-genesis-file --session-id 9s5BWpkrAW9F1XUf --party-file-names=step_1_for_leader_from_alice.json 
 --party-file-names=step_1_for_leader_from_bob.json --party-file-names=step_1_for_leader_from_carol.json 
 --fail-safe-file-name step_1_for_leader_from_dave.json --pre-mine-file-name ./esmeralda_pre_mine.json

---------------
---- Step 3 --- (Wallet 3 - Ledger/Party member)
---------------

pre-mine-create-verify-genesis-file --session-id F3AMUfX2f3TaVXiA --party-file-names=step_1_for_leader_from_alice.json 
 --party-file-names=step_1_for_leader_from_bob.json --party-file-names=step_1_for_leader_from_carol.json 
 --fail-safe-file-name step_1_for_leader_from_dave.json --pre-mine-file-name ./esmeralda_pre_mine.json

---------------
---- Step 3 --- (Wallet 4 - Ledger/Fail safe)
---------------

pre-mine-create-verify-genesis-file --session-id aFTZLw1oqzqAL6EY --party-file-names=step_1_for_leader_from_alice.json 
 --party-file-names=step_1_for_leader_from_bob.json --party-file-names=step_1_for_leader_from_carol.json 
 --fail-safe-file-name step_1_for_leader_from_dave.json --pre-mine-file-name ./esmeralda_pre_mine.json

Console outputs step 1 (wallet 1):

==============
Command Runner
==============

1. PreMineCreateScriptInputs(PreMineCreateScriptInputsArgs { alias: "alice" })


Concluded step 1 'pre-mine-create-script-inputs'
Your session ID is:                 'H6HvkTjpMC1ZhsQ7'
Your session's output directory is: 'C:\Users\pluto\Documents\tari_pre_mine\create\H6HvkTjpMC1ZhsQ7'
Session info saved to:              'C:\Users\pluto\Documents\tari_pre_mine\create\H6HvkTjpMC1ZhsQ7\step_1_for_leader_from_alice.json'
Send 'step_1_for_leader_from_.json' to leader for step 2

Minotari Console Wallet running... (Command mode completed)

Shutting down wallet... Done.

Console outputs step 2 (wallet 5):

==============
Command Runner
==============

1. PreMineCreateGenesisFile(PreMineCreateGenesisFileArgs { ... )


Concluded step 1 'pre-mine-create-genesis-file'
Your session ID is:                 'QDFCLTWnbuWXZB3j'
Your session's output directory is: 'C:\Users\hansie\Documents\tari_pre_mine\create\QDFCLTWnbuWXZB3j'
Outputs written to:                 'C:\Users\hansie\Documents\tari_pre_mine\create\QDFCLTWnbuWXZB3j\esmeralda_pre_mine.json'
Send 'step_2_for_parties.json' to parties for step 3

Minotari Console Wallet running... (Command mode completed)

Shutting down wallet... Done.

Console outputs step 3 (wallet 1):

==============
Command Runner
==============

1. PreMineCreateVerifyGenesisFile(PreMineCreateVerifyGenesisFileArgs { ... )


Concluded step 3 'pre-mine-create-verify-genesis-file'
Pre-mine file 'C:\Users\pluto\Documents\tari_pre_mine\create\H6HvkTjpMC1ZhsQ7\./esmeralda_pre_mine.json' successfully verified

Minotari Console Wallet running... (Command mode completed)

Shutting down wallet... Done.

What process can a PR reviewer use to test or verify this change?

Code review.
System-level testing.

Breaking Changes

  • None
  • Requires data directory on base node to be deleted
  • Requires hard fork
  • Other - Please specify

@hansieodendaal hansieodendaal requested a review from a team as a code owner July 26, 2024 12:49
@hansieodendaal hansieodendaal marked this pull request as draft July 26, 2024 12:49
Copy link

github-actions bot commented Jul 26, 2024

Test Results (CI)

    3 files    123 suites   39m 55s ⏱️
1 300 tests 1 299 ✅ 0 💤 1 ❌
3 892 runs  3 891 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit 8fdb9fd.

♻️ This comment has been updated with latest results.

@ghpbot-tari-project ghpbot-tari-project added P-acks_required Process - Requires more ACKs or utACKs P-reviews_required Process - Requires a review from a lead maintainer to be merged labels Jul 26, 2024
Copy link

github-actions bot commented Jul 26, 2024

Test Results (Integration tests)

35 tests   35 ✅  15m 8s ⏱️
11 suites   0 💤
 2 files     0 ❌

Results for commit 8fdb9fd.

♻️ This comment has been updated with latest results.

@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch from faa583b to 9c5500f Compare July 26, 2024 15:00
@hansieodendaal hansieodendaal marked this pull request as ready for review July 26, 2024 15:15
@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch from 9c5500f to 0b40266 Compare July 27, 2024 06:26
@ghpbot-tari-project ghpbot-tari-project added the CR-too_long Changes Requested - Your PR is too long label Jul 27, 2024
@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch 3 times, most recently from 82f2b63 to 5717c6e Compare July 29, 2024 03:16
Copy link
Collaborator

@SWvheerden SWvheerden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch from ffa6ceb to d79fa5b Compare July 31, 2024 12:59
@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch 3 times, most recently from 6e995f5 to 4c67010 Compare July 31, 2024 15:37
Added pre-mine creation command-line commands for the creation ceremony and
support within the ledger application.
@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch from 4c67010 to 4ab0fef Compare July 31, 2024 15:39
@hansieodendaal hansieodendaal force-pushed the ho_pre_mine_create_commands branch from 4ab0fef to 8fdb9fd Compare July 31, 2024 15:41
@SWvheerden SWvheerden merged commit 817729f into tari-project:development Aug 1, 2024
14 of 16 checks passed
@hansieodendaal hansieodendaal deleted the ho_pre_mine_create_commands branch August 1, 2024 07:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CR-too_long Changes Requested - Your PR is too long P-acks_required Process - Requires more ACKs or utACKs P-reviews_required Process - Requires a review from a lead maintainer to be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants